package components.map.item
{
	import capricornus.actor.NPC;
	import capricornus.item.attribute.ItemAttribute;
	
	import components.iteminfo.ItemInfoBarManager;
	import components.map.utils.SceneItemType;
	
	import flash.display.DisplayObject;
	import flash.events.MouseEvent;
	
	public class NPCItem extends SceneItem
	{
		public function NPCItem()
		{
			super();
			init();
		}
		
		private function init():void
		{
			_attribute.type = SceneItemType.NPC;
			
			var dis:DisplayObject = new ManPanel();
			dis.cacheAsBitmap = true;
			addChild( dis );
		}
		
		override public function clone():SceneItem
		{
			return new NPCItem();
		}
		
		override protected function onMouseDown(e:MouseEvent):void
		{
			ItemInfoBarManager.instance.showInfoBarByItem( this );
		}
	}
}